import request from "@/utils/requset.js";

export const apis = {
  add: (data) => {
    return request({
      url: "/preventionHiddenRegister/create",
      method: "post",
      data: data,
    });
  },
  addV2: (data) => {
    return request({
      url: "/preventionHiddenRegister/createAbnormal",
      method: "post",
      data: data,
    });
  },
  addV3: (data) => {
    return request({
      url: "/preventionHiddenRegister/createHiddenAbnormal",
      method: "post",
      data: data,
    });
  },
  query: (params) => {
    return request({
      url: "/preventionHiddenRegister/list",
      method: "get",
      params,
    });
  },
  querydj: (params) => {
    return request({
      url: "/preventionHiddenRegister/listdj",
      method: "get",
      params,
    });
  },
  del: (row) => {
    return request({
      url: "/preventionHiddenRegister/delete",
      method: "get",
      params: {
        id: row.id,
      },
    });
  },
  update: (data) => {
    return request({
      url: "/preventionHiddenRegister/update",
      method: "post",
      data: data,
    });
  },
  detail: (data) => {
    return request({
      url: "/preventionHiddenRegister/" + data,
      method: "get",
    });
  },
  updateRectification: (data) => {
    return request({
      url: "/preventionHiddenRegister/updateRectification",
      method: "post",
      data: data,
    });
  },
  updateReview: (data) => {
    return request({
      url: "/preventionHiddenRegister/updateReview",
      method: "post",
      data: data,
    });
  },
  updateTaskState: (data) => {
    return request({
      url: "/preventionCheckTask/updateTaskState",
      method: "post",
      data: data,
    });
  },
  zz: (params) => {
    return request({
      url: "/preventionDevice/list",
      method: "get",
      params,
    });
  },
};
